<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
      xmlns:h="http://xmlns.jcp.org/jsf/html"
      xmlns:f="http://xmlns.jcp.org/jsf/core"
      xmlns:p="http://primefaces.org/ui">

    <ui:composition>

        <p:dialog id="PartidoCreateDlg" widgetVar="PartidoCreateDialog" modal="true" resizable="false" appendTo="@(body)" header="#{bundle.CreatePartidoTitle}">
            <h:form id="PartidoCreateForm">
                <h:panelGroup id="display">
                    <p:panelGrid columns="2" rendered="#{partidoController.selected != null}">
                        <p:outputLabel value="#{bundle.CreatePartidoLabel_id}" for="id" />
                        <p:inputText id="id" value="#{partidoController.selected.id}" title="#{bundle.CreatePartidoTitle_id}" required="true" requiredMessage="#{bundle.CreatePartidoRequiredMessage_id}"/>
                        <p:outputLabel value="#{bundle.CreatePartidoLabel_codigo}" for="codigo" />
                        <p:inputText id="codigo" value="#{partidoController.selected.codigo}" title="#{bundle.CreatePartidoTitle_codigo}" required="true" requiredMessage="#{bundle.CreatePartidoRequiredMessage_codigo}"/>
                        <p:outputLabel value="#{bundle.CreatePartidoLabel_nombre}" for="nombre" />
                        <p:inputText id="nombre" value="#{partidoController.selected.nombre}" title="#{bundle.CreatePartidoTitle_nombre}" />
                        <p:outputLabel value="#{bundle.CreatePartidoLabel_codcatas}" for="codcatas" />
                        <p:inputText id="codcatas" value="#{partidoController.selected.codcatas}" title="#{bundle.CreatePartidoTitle_codcatas}" required="true" requiredMessage="#{bundle.CreatePartidoRequiredMessage_codcatas}"/>
                    </p:panelGrid>
                    <p:commandButton actionListener="#{partidoController.create}" value="#{bundle.Save}" update="display,:PartidoListForm:datalist,:growl" oncomplete="handleSubmit(args,'PartidoCreateDialog');"/>
                    <p:commandButton value="#{bundle.Cancel}" onclick="PartidoCreateDialog.hide()"/>
                </h:panelGroup>
            </h:form>
        </p:dialog>

    </ui:composition>
</html>
